package com.ruoyi.operation.service.impl;

import java.util.List;

import com.ruoyi.common.core.redis.RedisCache;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.operation.mapper.ProcessCourseMapper;
import com.ruoyi.operation.domain.ProcessCourse;
import com.ruoyi.operation.service.IProcessCourseService;

/**
 * 跑批信息Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-04-26
 */
@Service
public class ProcessCourseServiceImpl implements IProcessCourseService 
{
    @Autowired
    private ProcessCourseMapper processCourseMapper;

    @Autowired
    private RedisCache redisCache;

    /**
     * 查询跑批信息
     * 
     * @param id 跑批信息主键
     * @return 跑批信息
     */
    @Override
    public ProcessCourse selectProcessCourseById(Long id)
    {
        return processCourseMapper.selectProcessCourseById(id);
    }

    /**
     * 查询跑批信息列表
     * 
     * @param processCourse 跑批信息
     * @return 跑批信息
     */
    @Override
    public List<ProcessCourse> selectProcessCourseList(ProcessCourse processCourse)
    {
        return processCourseMapper.selectProcessCourseList(processCourse);
    }

    /**
     * 新增跑批信息
     * 
     * @param processCourse 跑批信息
     * @return 结果
     */
    @Override
    public int insertProcessCourse(ProcessCourse processCourse)
    {
        return processCourseMapper.insertProcessCourse(processCourse);
    }

    /**
     * 修改跑批信息
     * 
     * @param processCourse 跑批信息
     * @return 结果
     */
    @Override
    public int updateProcessCourse(ProcessCourse processCourse)
    {
        return processCourseMapper.updateProcessCourse(processCourse);
    }

    /**
     * 批量删除跑批信息
     * 
     * @param ids 需要删除的跑批信息主键
     * @return 结果
     */
    @Override
    public int deleteProcessCourseByIds(Long[] ids)
    {
        return processCourseMapper.deleteProcessCourseByIds(ids);
    }

    /**
     * 删除跑批信息信息
     * 
     * @param id 跑批信息主键
     * @return 结果
     */
    @Override
    public int deleteProcessCourseById(Long id)
    {
        return processCourseMapper.deleteProcessCourseById(id);
    }

    /**
     * 根据订单id添加跑批任务
     *
     * @param ids 订单id
     * @return 结果
     */
    @Override
    public int execProcessCourseByOrderId(Long[] ids) {
        return 0;
    }
}
